package com.zhl.scheduling.controller;

import com.zhl.scheduling.model.vo.ResultVO;
import com.zhl.scheduling.service.InitService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;

/**
 * @Author: ZhangLu In DLUT
 * @since: 1.0.0
 * @Description:用于提供系统初始化的相关接口
 */
@Api(value = "提供初始化请求", tags = "初始化相关")
@RestController
@CrossOrigin
@RequestMapping("/init")
public class InitController {

    @Resource
    private InitService initService;

    @ApiOperation("获取工件类别键值对")
    @GetMapping("/getCategoryOpt")
    public ResultVO getCategoryOpt(){
        return initService.getCategoryOpt();
    }

    @ApiOperation("获取部门类别键值对")
    @GetMapping("/getDepartmentOpt")
    public ResultVO getDepartmentOpt(){
        return initService.getDepartmentOpt();
    }
}
